IndexOf Method (T, Int32)

Wintellect PowerCollections

Collapse imageExpand ImageCollapseAll imageExpandAll imageDropDown imageDropDownHover imageCopy imageCopyHover image
[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

Finds the index of the first item, in the range of items extending from index to the end, that is equal to item.

Namespace: Wintellect.PowerCollections
Assembly:  PowerCollections (in PowerCollections.dll)

Syntax

C#
public virtual int IndexOf(
	T item,
	int index
)
Visual Basic (Declaration)
Public Overridable Function IndexOf ( _
	item As T, _
	index As Integer _
) As Integer
Visual C++
public:
virtual int IndexOf (
	T item, 
	int index
)

Parameters

item
T
The item to search fror.
index
Int32
The starting index of the range to check.

Return Value

The index of the first item in the given range that that is equal to item. If no item is equal to item, -1 is returned.

Remarks

The default implementation of equality for type T is used in the search. This is the equality defined by IComparable<T> or object.Equals.

See Also